package com.jxzn.locust.config;

import java.text.SimpleDateFormat;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.databind.SerializationFeature;

@Configuration
public class CommonConfig {

    @Bean
    public ObjectMapper objectMapper() {
        return new ObjectMapper().setDateFormat(new SimpleDateFormat("YYYY-mm-dd HH:MM"))
                .disable(SerializationFeature.FAIL_ON_EMPTY_BEANS);
    }

}
